package com.center.biz.impl;

import com.center.api.model.EduHelpMenu;
import com.center.api.remote.RemoteEduHelpMenuService;
import com.center.biz.dao.EduHelpMenuMapper;
import org.apache.dubbo.config.annotation.Service;
import org.springframework.beans.factory.annotation.Autowired;

import java.util.List;

@Service(version = "1.0",interfaceClass = RemoteEduHelpMenuService.class)
public class RemoteEduHelpMenuServiceImpl implements RemoteEduHelpMenuService {

    @Autowired
    private EduHelpMenuMapper eduHelpMenuMapper;

    @Override
    public int save(EduHelpMenu eduHelpMenu) {
        return eduHelpMenuMapper.insertSelective(eduHelpMenu);
    }

    @Override
    public int update(EduHelpMenu eduHelpMenu) {
        return eduHelpMenuMapper.updateByPrimaryKeySelective(eduHelpMenu);
    }

    @Override
    public int delete(int id) {
        return eduHelpMenuMapper.deleteByPrimaryKey(id);
    }

    @Override
    public List<EduHelpMenu> select(EduHelpMenu eduHelpMenu) {
        return null;
    }

    @Override
    public EduHelpMenu getById(int id) {
        return eduHelpMenuMapper.selectByPrimaryKey(id);
    }
}
